<template>
  <div class="app">
    <!-- ref结合 this.$refs.xxx 可以快速获取dom -->
    <!-- ref  写在标签上是一个属性 值随便写(语义化)    获取 this.$refs.xxx-->
    <div ref="chartRef" id="chart"></div>
    <BaseDialog ref="dialogRef" :isShow.sync='isShow' />
    <button @click="close">关闭弹窗</button>
  </div>
</template>

<script>
import BaseDialog from './components/BaseDialog'
export default {
  data() {
    return {
      isShow: true,
    }
  },
  components: {
    BaseDialog
  },
  mounted() {
    console.log(this.$refs.chartRef)
    console.log(this.$refs.dialogRef)
  },
  methods: {
   close() {
      this.$refs.dialogRef.closeDialog()
   }
  }
}
</script>

<style>
</style>